<?php
include '../global.php';
include LIB_PATH.'biz/search/SearchInfomation.php';
include LIB_PATH.'utils/showContent.php';
include LIB_PATH.'db/db.php';

session_start();

/* 获取当前id的数据 */
/* 应当添加一些错误检查 */
$tableName = $_GET['type'];
$tableID = $_GET['id'];
$queryStr = sprintf('select * from %s where id=%s', $tableName, $tableID );
$query = mysql_query($queryStr, $GLOBALS['DB']);
if(!$query){
    /* 出错 */
    die("无法执行更新操作");
}
$result = mysql_fetch_array($this->query);
if($result==false){
    die("无法执行更新操作");
}
/* 判断是否有权限修改 */
?>
<html>
    <head>
        <meta charset="UTF-8">
        <script language="javascript" type="text/javascript" src="../js/My97DatePicker/WdatePicker.js">
        </script>
    </head>
    <body>
        <form action="" method="post">
        <center>
        <table>
            <?php
                $temp = new Template();
                if(isset($_SESSION['awards'])){
                    $temp->awardsTemp($_SESSION['awards']);
                }else{
                    $temp->awardsTemp();
                }
            ?>
            <tr>
                <td></td>
                <td><input type="submit" value="修改"/></td>
            </tr>
        </table>
        </center>
    </form>
</body>
</html>
